import Vue from 'vue'
import Element from 'element-ui'
import 'element-ui/lib/theme-chalk/index.css'
import App from './App.vue'
import router from './router'

import axios from 'axios'

import * as echarts from 'echarts'

// import echarts from 'echarts'
// Vue.prototype.$echarts = echarts

import scroll from 'vue-seamless-scroll' // 滚动
import VueAwesomeSwiper from 'vue-awesome-swiper' // 轮播插件

import 'swiper/dist/css/swiper.css'

import './assets/css/global.css'

Vue.prototype.$echarts = echarts

Vue.use(VueAwesomeSwiper)

Vue.use(scroll)

Vue.use(Element)

// 配置请求的跟路径
// axios.defaults.baseURL ='http://119.3.74.121:5500'
// axios.defaults.baseURL ='http://192.168.3.173:5500'
Vue.prototype.$http = axios.create({
  baseURL: '/'
})

// 响应拦截器
axios.interceptors.response.use(ret => {
  var res = ret.data
  return res
})

Vue.config.productionTip = false

new Vue({
  router,
  render: h => h(App)
}).$mount('#app')
